"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Cheap deep clone utility
 */
function clone(obj) {
    const newObj = (obj instanceof Array) ? [] : {};
    for (const i in obj) {
        if (obj[i] && typeof obj[i] === 'object') {
            newObj[i] = clone(obj[i]);
        }
        else {
            newObj[i] = obj[i];
        }
    }
    return newObj;
}
exports.clone = clone;
